package test.v3;

import com.baishui.context.ApplicationContext;
import com.baishui.context.support.ClassPathXmlApplicationContext;
import com.baishui.service.BaishuiV3Service;
import org.junit.Assert;
import org.junit.Test;

public class Step03_ApplicationContextTestV3 {

	@Test
	public void testGetBeanProperty() {
		ApplicationContext ctx = new ClassPathXmlApplicationContext("litespring-v3.xml");
		BaishuiV3Service petStore = (BaishuiV3Service)ctx.getBean("baishuiV3Service");
		
		Assert.assertNotNull(petStore.getCar());
		Assert.assertNotNull(petStore.getHouse());
		Assert.assertEquals(1, petStore.getVersion());
		
	}

}
